<!DOCTYPE html>
<html>
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="maximum-scale=1.0,minimum-scale=1.0,user-scalable=0,width=device-width,initial-scale=1.0"/>
    <title>服务</title>
    <link rel="stylesheet" type="text/css" href="../../css/aui-win.css" />
    <style>
        a {
            text-decoration: none;
        }
        body {
            background:white !important;
        }
       
        #news ul li a.active {
            background-color: #d9e4e9;
        }
        #inEc ul,.ecinfoList {
            padding-top: 5px;
            text-align: center;
        }
        .ecinfoList li, #inEc ul li, #adlist li {
            text-align: center;
            float: left;
            width: 20%;
            background-color: #fff;
         	margin:5px 0;
         	padding:0 2%;
        }
        .ecinfoList li img, #inEc ul li img, #adlist li img {
         height:50px;
           width:80%;
           margin-left:10%;
        }
        h3 {
            width: 100%;
            font-size: 16px;
            background: #EEEEEE;
            line-height: 40px;
             font-weight: 500;
             text-indent:1em;
             height:40px;
        }
        h4 {
            width:100%;
            text-align: center;
            margin: 0;
            padding: 0;
            height: 20px;
            font-size:16px;
            font-weight: 500;
        }
        *{
            margin: 0;
            padding: 0;
        }
        body{
            overflow-x:hidden;
        }
        #slide ul{
            height: 150px;
        }
        #slide a{
            display: block;
            float: left;
        }
        #slide img{
            width: 100%;
            height: 100%;
        }
        #showInfo b{
            width: 8px;
            height: 8px;
            display: block;
            border:1px solid black;
            border-radius: 8px;
            float: left;
            background: blue;
            position: absolute;
        }
        #lunbo{
            position: relative;
            height: 150px;
            overflow: hidden;
        }
        #divLeft{
            width: 20px;
            height: 20px;
            position: absolute;
            z-index: 666;
        }
        #divRight{
            width: 20px;
            height: 20px;
            position: absolute;
            z-index: 666;
            left: 100%;
            margin-left: -20px;
        }
     /*slide*/
 .swipe {
        overflow: hidden;
        visibility: hidden;
        position: relative;
    }
    .swipe-wrap {
        overflow: hidden;
        position: relative;
    }
    .swipe-wrap > figure {
    	height:130px;
        float: left;
        width: 100%;
        position: relative;
    }
    #slider {
        margin: 0px auto; /* 居中对齐 */
    }

    figure {
        margin: 0;/* 对齐，四周宽度都为0，在轮播的时候，以整张图片进行移动 */
    }
    .swipe-wrap img {
		height: 130px;
		width: 100%;
	}
    nav{
	    position: absolute;
		right: 10px;
		bottom: 12px;
		overflow: hidden;
    }
    #position {
        text-align: center;
        list-style: none;
        margin: 0;
        padding: 0
    }
    #position li {
        width: 6px;
        height: 6px;
        border-radius: 50%;
        background: #141414;
        margin: 0 2px;
        cursor: pointer;
        float: left;
    }
    #position li.on {
        background-color: #1293dc;
    }
    .ecinfoList h4{
        display: none;
        width:80%;
    	margin-left:15%;
    	font-size:12px;
    	color:#999;
    }
    #inEc h4{
    	width:80%;
    	margin-left:15%;
    	font-size:12px;
    	color:#999;
    }
    .ecinfoList p{
    	height:20px;
    	overflow:hidden;
    	width:80%;
    	margin-left:15%;
    	text-overflow:ellipsis;
    	white-space:nowrap; 
    }
    </style>
</head>
<body>

	<div class="div_loding_img">
		数据加载中
	</div>
<header class="aui-bar aui-bar-nav aui-bar-yunzo" id="aui-header">
		<a class="aui-btn aui-bar-yunzo aui-pull-left" id="back"> <span class="aui-iconfont aui-icon-left"></span></a>
		<div class="aui-title" id="title">
			服务
		</div>
</header>
<div class="margin_div"></div>
  <!-- 顶部轮播图 -->
     <div id="slider" class="swipe" style="visibility:visible;">
		    <div class="swipe-wrap">
		    </div>
		    <nav>
			    <ul id="position">
			      
			    </ul>
			</nav>
		</div>
<!--内部电商-->
<div id="inEc">
    <h3>云筑圈服务</h3>
    <ul>
    	<li>
            <a><img src="../../image/home/ecinfo/xiongdanfen.png" onclick="openthreepage('ecinfo_xiongdanfen.html?infoid=88888888888888888888888888800001&name=熊胆粉')" ><h4>熊胆粉</h4></a>
        </li>
        <li>
            <a><img src="../../image/home/ecinfo/dashuju.png" onclick="openthreepage('ecinfo_xiongdanfen.html?infoid=88888888888888888888888888800002&name=大数据')" ><h4>大数据</h4></a>
        </li>  
        <li>
            <a><img src="../../image/home/ecinfo/APPdingzhi.png" onclick="openthreepage('ecinfo_xiongdanfen.html?infoid=88888888888888888888888888800003&name=APP定制')" ><h4>APP定制</h4></a>
        </li>
        <li>
            <a><img src="../../image/home/ecinfo/hongjiu.png" onclick="openthreepage('ecinfo_xiongdanfen.html?infoid=88888888888888888888888888800004&name=红酒')" ><h4>红酒</h4></a>
        </li>
    </ul>
</div>

<!--最下方的生活服务-->
<div id="service">
    <!--    <h3>内部电商</h3>
        <ul class="ecinfoList">
            <li><a><img src="../../image/home/ecinfo/daijieru1.png" onclick="weijieru('h41')" ><h4 id="h41">待接入</h4></a></li>
            <li><a><img src="../../image/home/ecinfo/daijieru2.png" onclick="weijieru('h42')" ><h4 id="h42">待接入</h4></a></li>
            <li><a><img src="../../image/home/ecinfo/daijieru3.png" onclick="weijieru('h43')" ><h4 id="h43">待接入</h4></a></li>
            <li><a><img src="../../image/home/ecinfo/daijieru4.png" onclick="weijieru('h44')" ><h4 id="h44">待接入</h4></a></li>
       </ul>  --> 
</div>

<script src="../../script/jquery-1.10.2.min.js"></script>
<script src="../../script/common.js"></script>
<script src="../../script/swipe.js"></script>
<script type="text/javascript">
var content;
$(document).ready(function(){
	content=$("#service");
	goback("../main.html");
	getaAd();
});
//获取投放广告
sTart_Stop();
function getaAd() {
	var Post=basedata('adinfo')+"&adtype=2";
	$.ajax({
		url:'../../../api/getadimagebymidlist',
		type:'post',
		data:Post,
		success:function(msg){
			if(msg.code ==100){
				console.log(msg);
				var len=msg.data.length;
				var html='';
				var htmll='';
				for(var i=0;i<len;i++){
					//html+='<figure><div class="face faceInner"><img src="'+msg.data[i].n2+'" width="100%" height="100%" /></div></figure>';
					html+="<figure><div class='face faceInner'><img src='"+msg.data[i].n2+"' width='100%' height='100%' onclick=\"openpageparam('adinfo.html','adid="+msg.data[i].n0+"')\" /></div></figure>";
					if(i==0){
						htmll+='<li class="no"></li>';
					}
					else{
						htmll+='<li class=""></li>'
					}
				}
				var swipeWrap=$(".swipe-wrap");
				var positions=$("#position");
				swipeWrap.append(html);
				positions.append(htmll);
				initSlide();
			}else{
				$("body").append('<div class="wuwang"><img src="../../image/iconfont-wangluo.png"><p>网络拥堵，信息塞车</p></div>')
			}
		}
	});
}

//定制的图片轮播函数
function initSlide() {
	var bullets = document.getElementById('position').getElementsByTagName('li');
	var slider=Swipe(document.getElementById('slider'), {
            auto: 5000,
            continuous: true,
            disableScroll : true,
    		stopPropagation : true,
            callback: function(pos) {
                var i = bullets.length;
                while(i--){
                    bullets[i].className = ' ';
                }
                bullets[pos].className = 'on';
            }
        });
}
function weijieru(num){
    $('#'+num).fadeIn(1000);
    setTimeout(function(){
        $('#'+num).fadeOut(1000);
    },3000)
    alert("请联系商会秘书处接入……")
}
function openthreepage(htmlName){
    window.location = htmlName;
}
var pagesize=100;
var post=basedata('busessinfo')+"&type=0"+"&pagesize="+pagesize;
ajaxcocRequest('../../../api/group/getgroupecprodinfolist', 'post', post, function(msg){
	if(msg.code ==100){
		var html="";
		if(msg.data!=null)
		{
			for(var j=0;j<msg.data.length;j++)
			{
				html+="<h3>"+msg.data[j].n1+"</h3><ul class='ecinfoList'>";
				var neibu=msg.data[j].n4
				if(neibu.length==0){
					html+="<li><a><img src='../../image/home/ecinfo/daijieru1.png' onclick='weijieru()' ></a></li><li><a><img src='../../image/home/ecinfo/daijieru2.png' onclick='weijieru()' ></a></li><li><a><img src='../../image/home/ecinfo/daijieru3.png' onclick='weijieru()' ></a></li><li><a><img src='../../image/home/ecinfo/daijieru4.png' onclick='weijieru()' ></a></li>";
				}
				else{
					for(var i=0;i<neibu.length;i++){
						html+="<li><a href='ecinfo_xiongdanfen.html?infoid="+neibu[i].n0+"&name="+neibu[i].n1+"'><img src='"+neibu[i].n3+"'></a><p>"+neibu[i].n1+"</p></li>" ;
					}
				}
				
				html+="</ul>";
			}
			
		}else
		{
			html="<h3>服务</h3><ul class='ecinfoList' ><li><a><img src='../../image/home/ecinfo/daijieru1.png' onclick='weijieru()' ></a></li><li><a><img src='../../image/home/ecinfo/daijieru2.png' onclick='weijieru()' ></a></li><li><a><img src='../../image/home/ecinfo/daijieru3.png' onclick='weijieru()' ></a></li><li><a><img src='../../image/home/ecinfo/daijieru4.png' onclick='weijieru()' ></a></li></ul>";
		}
		content.html(html);
		$(".ecinfoList img").error(function(){
			$(this).attr("src","../../image/defaultImg2.png");
		});
	}
	else{
		alert(JSON.stringify(msg));
	}
})
</script>
</body>
</html>